//
//  TypeCell.m
//  RENTVISITOR
//
//  Created by wonder on 2017/9/8.
//  Copyright © 2017年 UNN. All rights reserved.
//

#import "TypeCell.h"
#import "RentVieitor.h"

@implementation TypeCell {
    
    UILabel *textLabel;
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        
        
        [self creatViw];
        
    }
    return self;
}

- (void)creatViw {
    
    textLabel = [[UILabel alloc] initWithFrame:CGRectMake(20, 5,KWidth , 30)];
    textLabel.textColor = [Utils colorConvertFromString:@"#333333"];
    textLabel.textAlignment = NSTextAlignmentLeft;
    textLabel.font = [UIFont systemFontOfSize:13];
    [self.contentView addSubview:textLabel];
}

- (void)setText:(NSString *)text {
    
    _text = text;
    textLabel.text = _text;
    
}

- (void)setColor:(NSString *)color {
    
    _color = color;
    if ([_color isEqualToString:@"yes"]) {
        textLabel.textColor = [Utils colorConvertFromString:@"#f4630b"];
    }else {
        textLabel.textColor = [Utils colorConvertFromString:@"#333333"];
    }
    
    
}
@end
